<?php /** @var User $thatUser */ ?>
<div id="main">
        <div id="user-center-sidebar-left">
            <?php $this->load->view('home/user-center/sidebar'); ?>
        </div>
        <div id="user-center-body">
                <?php if (isset($thatUser) && $thatUser->getId() > 0): ?>
                    <?php $thatUserInfo = $thatUser->getUserInfo(); ?>
                    <ul class="nav nav-tabs" id="userinfo-tab-menu">
                        <!--<li><a href="#basic" data-toggle="tab">基本资料</a></li>-->
                        <li class="active"><a href="#user-info" data-toggle="tab">详细资料</a></li>
                        <li><a href="#user-avatar" data-toggle="tab">用户头像</a></li>
                        <li><a href="#resendemail" data-toggle="tab">激活邮箱</a></li>
                        <li><a href="#realname" data-toggle="tab">实名认证</a></li>
                        <li><a href="#security" data-toggle="tab">安全设置</a></li>
                        <li><a href="#binding" data-toggle="tab">绑定账户</a></li>
                    </ul>
                    <div class="tab-content">
                        <!--
                        <div class="tab-pane fade in active" id="basic">
                            <form>
                                <div class="input-group">
                                    <label for="user-id" class="input-group-addon">用户ID</label>
                                    <input type="number" class="form-control" name="user_id" id="user-id" value="<?php echo $thatUser->getId(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-email" class="input-group-addon">用户账号</label>
                                    <input type="email" class="form-control" name="user_email" id="user-email" value="<?php echo $thatUser->getEmail(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-power" class="input-group-addon">用户权限</label>
                                    <input type="number" class="form-control" name="user_power" id="user-power" value="<?php /*echo $thatUser->getPower(); */?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-reg-ip" class="input-group-addon">注册IP</label>
                                    <input type="text" class="form-control" name="user_reg_ip" id="user-reg-ip" value="<?php /*echo $thatUser->getRegIp(); */?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-reg-time" class="input-group-addon">注册时间</label>
                                    <input type="text" class="form-control" name="user_reg_time" id="user-reg-time" value="<?php echo $thatUser->getRegTime(); ?>" disabled/>
                                </div>
                            </form>
                            <?php if ($thatUser->getPower() == 0): ?>
                                <button class="btn btn-primary form-control" onclick="UserManager.resendActivationEmail('<?php echo $thatUser->getId() ?>')">重发验证邮件</button>
                            <?php endif; ?>
                        </div>
                        -->
                        <div class="tab-pane fade in active" id="user-info">
                            <form id="user-info-form" method="post">
                                <input type="hidden" name="user_id" id="user_id" value="<?php echo $thatUser->getId(); ?>"/>
                                <div class="input-group">
                                    <label for="user-email" class="input-group-addon">用户账号</label>
                                    <input type="email" class="form-control" name="user_email" id="user-email" value="<?php echo $thatUser->getEmail(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-nick_name" class="input-group-addon">昵称</label>
                                    <input type="text" class="form-control" name="user_nick_name"  value="<?php echo $thatUser->getNickname(); ?>" />
                                </div>
                                <div class="input-group">
                                    <label for="user-sex" class="input-group-addon">性别</label>
                                    <select class="form-control" name="user_sex" id="user-sex">
                                        <option value="1" <?php echo $thatUserInfo->getSex() == 1 ? 'selected' : ''; ?>>男</option>
                                        <option value="2" <?php echo $thatUserInfo->getSex() == 2 ? 'selected' : ''; ?>>女</option>
                                    </select>
                                </div>
                                <div class="input-group">
                                    <label for="Ubirthday" class="input-group-addon">生日</label>
                                    <input type="birthday" class="form-control" readonly name="Ubirthday" id="Ubirthday" value="<?php echo $thatUserInfo->getBirthday()?>" style="background:url(<?php echo base_url('public/images/birthday.png'); ?> no-repeat 190px 8px !important;"/>
                                    <div class="calender">
                                      <div class="calenderContent">
                                        <div class="calenderTable">
                                          <div class="getyear">
                                            <select id="year">
                                              <option value="1980">1980年</option>
                                              <option value="1981">1981年</option>
                                              <option value="1982">1982年</option>
                                              <option value="1983">1983年</option>
                                              <option value="1984">1984年</option>
                                              <option value="1985">1985年</option>
                                              <option value="1986">1986年</option>
                                              <option value="1987">1987年</option>
                                              <option value="1988">1988年</option>
                                              <option value="1989">1989年</option>
                                              <option value="1990">1990年</option>
                                              <option value="1991">1991年</option>
                                              <option value="1992">1992年</option>
                                              <option value="1993">1993年</option>
                                              <option value="1994">1994年</option>
                                              <option value="1995">1995年</option>
                                              <option value="1996">1996年</option>
                                              <option value="1997">1997年</option>
                                              <option value="1998">1998年</option>
                                              <option value="1999">1999年</option>
                                              <option value="2000">2000年</option>
                                              <option value="2001">2001年</option>
                                              <option value="2002">2002年</option>
                                              <option value="2003">2003年</option>
                                              <option value="2004">2004年</option>
                                              <option value="2005">2005年</option>
                                              <option value="2006">2006年</option>
                                              <option value="2007">2007年</option>
                                              <option value="2008">2008年</option>
                                              <option value="2009">2009年</option>
                                              <option value="2010">2010年</option>
                                              <option value="2011">2011年</option>
                                              <option value="2012">2012年</option>
                                              <option value="2013">2013年</option>
                                              <option value="2014">2014年</option>
                                              <option value="2015">2015年</option>
                                            </select>
                                            <select id="month">
                                              <option value="1">1月</option>
                                              <option value="2">2月</option>
                                              <option value="3">3月</option>
                                              <option value="4">4月</option>
                                              <option value="5">5月</option>
                                              <option value="6">6月</option>
                                              <option value="7">7月</option>
                                              <option value="8">8月</option>
                                              <option value="9">9月</option>
                                              <option value="10">10月</option>
                                              <option value="11">11月</option>
                                              <option value="12">12月</option>
                                            </select>
                                          </div>
                                          <div class="tablebg">
                                            <table id="calender" class="calendertb" cellpadding="0" cellspacing="1">
                                              <tbody>
                                                <tr bgcolor="#D6D6D6">
                                                  <th class="weekend">日</th>
                                                  <th>一</th>
                                                  <th>二</th>
                                                  <th>三</th>
                                                  <th>四</th>
                                                  <th>五</th>
                                                  <th class="weekend noborder">六</th>
                                                </tr>
                                                <tr>
                                                  <td class="weekend2">&nbsp;</td>
                                                  <td class="">&nbsp;</td>
                                                  <td class="">1</td>
                                                  <td class="">2</td>
                                                  <td class="">3</td>
                                                  <td class="">4</td>
                                                  <td class="">5</td>
                                                </tr>
                                                <tr>
                                                  <td class="">6</td>
                                                  <td class="">7</td>
                                                  <td class="">8</td>
                                                  <td class="">9</td>
                                                  <td class="tdtoday">10</td>
                                                  <td class="">11</td>
                                                  <td class="">12</td>
                                                </tr>
                                                <tr>
                                                  <td class="">13</td>
                                                  <td class="">14</td>
                                                  <td class="">15</td>
                                                  <td class="">16</td>
                                                  <td class="">17</td>
                                                  <td class="">18</td>
                                                  <td class="">19</td>
                                                </tr>
                                                <tr>
                                                  <td class="">20</td>
                                                  <td class="">21</td>
                                                  <td class="">22</td>
                                                  <td class="">23</td>
                                                  <td class="">24</td>
                                                  <td class="">25</td>
                                                  <td class="">26</td>
                                                </tr>
                                                <tr>
                                                  <td class="">27</td>
                                                  <td class="">28</td>
                                                  <td class="">29</td>
                                                  <td class="">30</td>
                                                  <td>&nbsp;</td>
                                                  <td class="">&nbsp;</td>
                                                  <td class="weekend2">&nbsp;</td>
                                                </tr>
                                                <tr>
                                                  <td class="weekend2">&nbsp;</td>
                                                  <td>&nbsp;</td>
                                                  <td>&nbsp;</td>
                                                  <td>&nbsp;</td>
                                                  <td>&nbsp;</td>
                                                  <td class="">&nbsp;</td>
                                                  <td class="weekend2">&nbsp;</td>
                                                </tr>
                                              </tbody>
                                            </table>
                                          </div>
                                        </div>
                                      </div>
                                    </div>
                                </div>
                                <div class="input-group">
                                    <label for="user_contact_type" class="input-group-addon">联系方式</label>
                                    <select id="user_contact_type" name="user_contact_type" class="form-control" style="float:left; width:34%">
                                        <option value="<?php echo _ContactType_LongPhone ?>" <?php echo (($thatUserInfo->getDefaultContactType())==_ContactType_LongPhone)?"selected":""; ?> >长号</option>
                                        <option value="<?php echo _ContactType_ShortPhone ?>" <?php echo (($thatUserInfo->getDefaultContactType())==_ContactType_ShortPhone)?"selected":""; ?>>短号</option>
                                        <option value="<?php echo _ContactType_Qq ?>" <?php echo (($thatUserInfo->getDefaultContactType())==_ContactType_Qq)?"selected":""; ?>>QQ</option>
                                    </select>
                                    <input type="text" id="user_phone" name="user_phone" class="form-control js-user-contact" style="float:left; width:66%" value="<?php echo $thatUserInfo->getPhone()?>"/>
                                    <input type="text" id="user_phone_short" name="user_phone_short" class="form-control js-user-contact" style="float:left; width:66%; display:none" value="<?php echo $thatUserInfo->getPhoneShort()?>"/>
                                    <input type="text" id="user_qq" name="user_qq" class="form-control js-user-contact" style="float:left; width:66%; display:none" value="<?php echo $thatUserInfo->getQq()?>"/>
                                </div>
                                <div class="input-group">
                                    <label for="location" class="input-group-addon">所在地</label>
                                    <div id="location">
                                        <select name="prov" class="prov form-control" style="float:left; width:34%"></select>
                                        <select name="city" class="city form-control" disabled="disabled" style="float:left; width:33%"></select>
                                        <select name="dist" class="dist form-control" disabled="disabled" style="float:left; width:33%"></select>
                                    </div>
                                </div>
                                <div class="input-group">
                                    <label for="user-profile" class="input-group-addon">个人简介</label>
                                    <input type="text" class="form-control" name="user_profile" id="user-profile" value="<?php echo $thatUserInfo->getProfile(); ?>"/>
                                </div>
                                <!--<div class="input-group">
                                    <label for="user-avatar-hash" class="input-group-addon">头像文件Hash</label>
                                    <input type="text" class="form-control" name="user_avatar_hash" id="user-avatar-hash" value="<?php echo $thatUserInfo->getAvatarHash(); ?>"
                                           disabled/>
                                </div>-->
                                <input type="submit" class="form-control" id="ok-infor" value="修改"/>
                            </form>
                        </div>
                        <div class="tab-pane fade" id="user-avatar">
                            <div id="now-avatar" class="text-center">
                                <div class="well well-sm" style="display: inline-block; margin-top:30px;">
                                    <img src="<?php echo $thatUser->getDisplayAvatarUrl() ?>" alt="用户头像"/>
                                </div>
                            </div>
                            <div id="crop-avatar" style="display:none; overflow: hidden;">
                                <div id="avatar-preview" class="well well-sm" style="float:left; margin: 5px; display: inline-block;">
                                    <div id="avatar-preview-container" style="width: 128px; height: 128px; overflow:hidden;">
                                        <img id="avatar-preview-img"/>
                                    </div>
                                </div>

                                <div id="avatar-picker" class="well well-sm" style="float:left; margin: 5px; display: inline-block;">
                                    <div id="avatar-picker-container" style="display: inline;">
                                        <img id="avatar-picker-img"/>
                                    </div>
                                </div>
                            </div>

                            <div class="clearfix"></div>

                            <div id="btn-container" class="text-center" style="margin-top: 10px">
                                <button id="pick-file" class="btn btn-default">选择图片</button>
                                <button id="submit" class="btn btn-success">确认上传</button>
                            </div>
                        </div>
                        <?php if($thatUser->getPower()<1): ?>
                            <div class="tab-pane fade" id="resendemail">
                                <h3 class="alert alert-warning text-center">未进行邮箱激活</h3>
                                <p style="text-align: center;">邮箱：<?php echo $thatUser->getEmail(); ?></p>
                                <div class="input-group">
                                    <input type="button" class="form-control" name="ok-resendemail" id="ok-resendemail" value="重发激活邮件" />
                                </div>
                                <div class="text-center">
                                </div>
                            </div>
                        <?php else: ?>
                            <div class="tab-pane fade" id="resendemail">
                                <h3 class="alert alert-warning text-center">邮箱已激活</h3>
                                <p style="text-align: center;">邮箱：<?php echo $thatUser->getEmail(); ?></p>
                                <div class="text-center">
                                </div>
                            </div>
                        <?php endif; ?>
                        <div class="tab-pane fade" id="realname">
                            <?php if ($thatUser->getStudentInfoId()): ?>
                                <?php $thatStudentInfo = $thatUser->getStudentInfo(); ?>
                                <h3 class="alert alert-info text-center">已通过实名认证</h3>
                                <form>
                                    <div class="input-group">
                                        <label for="school-name" class="input-group-addon">学校</label>
                                        <input type="text" class="form-control" name="school_name" id="school-name" value="<?php echo $thatStudentInfo->getSchool()->getName(); ?>" disabled/>
                                    </div>
                                    <div class="input-group">
                                        <label for="student-num" class="input-group-addon">学号</label>
                                        <input type="text" class="form-control" name="student_num" id="student-num" value="<?php echo $thatStudentInfo->getStudentNum(); ?>" disabled/>
                                    </div>
                                    <div class="input-group">
                                        <label for="student-name" class="input-group-addon">姓名</label>
                                        <input type="text" class="form-control" name="student_name" id="student-name" value="<?php echo $thatStudentInfo->getStudentName(); ?>" disabled/>
                                    </div>
                                    <div class="input-group">
                                        <label for="grade" class="input-group-addon">年级</label>
                                        <input type="number" class="form-control" name="grade" id="grade" value="<?php echo $thatStudentInfo->getGrade(); ?>" disabled/>
                                    </div>
                                    <div class="input-group">
                                        <label for="major" class="input-group-addon">专业</label>
                                        <input type="text" class="form-control" name="major" id="major" value="<?php echo $thatStudentInfo->getMajor(); ?>" disabled/>
                                    </div>
                                </form>
                            <?php else: ?>
                                <h3 class="alert alert-warning text-center">未通过实名认证</h3>
                                <div class="input-group">
                                    <input type="button" class="student-real-name-auth form-control" name="ok-realname" id="ok-realname" value="马上进行实名认证" />
                                </div>
                                <div class="text-center">
                                </div>
                            <?php endif; ?>
                        </div>
                        <div class="tab-pane fade" id="security">
                            <form id="change-password-form" method="post">
                                <div class="input-group">
                                    <label for="now-password" class="input-group-addon">当前密码</label>
                                    <input type="password" class="form-control" name="now-password" id="now-password" placeholder="当前密码" />
                                </div>
                                <div class="input-group">
                                    <label for="new-password" class="input-group-addon">重设密码</label>
                                    <input type="password" class="form-control" name="new-password" id="new-password" placeholder="重设密码" />
                                </div>
                                <!--
                                <div class="input-group">
                                    <label for="captcha-password" class="input-group-addon">验证码 </label>
                                    <input type="text" class="form-control" name="captcha-password" id="captcha-password" placeholder="验证码" />
                                    <img src="" width="135" height="34" style="border:0; margin-left:10px; cursor:pointer;" alt=" ">
                                </div>
                                -->
                                <div class="input-group">
                                    <input type="submit" class="form-control" name="ok-password" id="ok-password" value="修改密码" />
                                </div>
                                <!--
                                <div class="input-group">
                                    <label for="user-login-ip" class="input-group-addon">最后登录IP</label>
                                    <input type="text" class="form-control" name="user_login_ip" id="user-login-ip" value="<?php echo $thatUser->getLoginIp(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-login-time" class="input-group-addon">最后登录时间</label>
                                    <input type="text" class="form-control" name="user_login_time" id="user-login-time" value="<?php echo $thatUser->getLoginTime(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-act-ip" class="input-group-addon">最后活动IP</label>
                                    <input type="text" class="form-control" name="user_act_ip" id="user-act-ip" value="<?php echo $thatUser->getActIp(); ?>" disabled/>
                                </div>
                                <div class="input-group">
                                    <label for="user-act-time" class="input-group-addon">最后活动时间</label>
                                    <input type="text" class="form-control" name="user_act_time" id="user-act-time" value="<?php echo $thatUser->getActTime(); ?>" disabled/>
                                </div>
                                -->
                            </form>
                        </div>
                        <div class="tab-pane fade" id="binding">
                            <?php if(!isset($thatWeiboUserInfo) || $thatWeiboUserInfo->getId() === ''): ?>
                            <a href="<?php echo $weibourl; ?>" class="binding-weibo">绑定微博</a>
                            <?php else: ?>
                            <h3 class="alert alert-warning text-center">已成功绑定微博</h3>
                            <p style="text-align: center;">微博：<?php echo $thatWeiboUserInfo->getName(); ?></p>
                            <div class="text-center"></div>
                            <?php endif; ?>
                        </div>
                    </div>
                <?php endif; ?>
        </div>
</div>

<script>
    $(function () {
        var JCrop_x1 = 0;
        var JCrop_y1 = 0;
        var JCrop_x2 = 0;
        var JCrop_y2 = 0;
        var JCrop_w = 0;
        var JCrop_h = 0;

        var jcrop_api;

        var $avatarPreview = $('#avatar-preview');
        var $avatarPicker = $('#avatar-picker');
        var $avatarPreviewContainer = $('#avatar-preview-container');
        var $avatarPickerContainer = $('#avatar-picker-container');

        var reader = new FileReader();

        reader.onload = function (evt) {
            if (jcrop_api) {
                jcrop_api.destroy();
                jcrop_api = null;
            }
            $('#avatar-preview-img').attr('src', evt.target.result);
            $('#avatar-picker-img').Jcrop({
                boxWidth: 400,
                boxHeight: 0,
                aspectRatio: 1,
                bgFade: true,
                onChange: function (c) {
                    JCrop_x1 = c.x;
                    JCrop_y1 = c.y;
                    JCrop_x2 = c.x2;
                    JCrop_y2 = c.y2;
                    JCrop_w = c.w;
                    JCrop_h = c.h;
                    var bounds = this.getBounds();
                    if (parseInt(c.w) > 0) {
                        var rx = $avatarPreviewContainer.width() / c.w;
                        var ry = $avatarPreviewContainer.height() / c.h;
                        $('#avatar-preview-img').css({
                            width: Math.round(rx * bounds[0]) + 'px',
                            height: Math.round(ry * bounds[1]) + 'px',
                            marginLeft: '-' + Math.round(rx * c.x) + 'px',
                            marginTop: '-' + Math.round(ry * c.y) + 'px'
                        });
                    }
                }
            }, function () {
                this.setImage(evt.target.result);
                jcrop_api = this;
            });
        };

        var uploader = new plupload.Uploader({
            runtimes: 'html5,flash,silverlight,html4',
            browse_button: 'pick-file',
            container: document.getElementById('btn-container'),
            chunk_size: '1mb',
            max_file_size: '100mb',
            url: '<?php echo base_url('api/uploadAvatar')?>',
            multipart_params: {},
            multi_selection: false,
            unique_names: true,
            file_data_name: "file",
            flash_swf_url: '<?php echo base_url('public/libraries/plupload-2.1.1/Moxie.swf') ?>',
            silverlight_xap_url: '<?php echo base_url('public/libraries/plupload-2.1.1/Moxie.xap') ?>',
            init: {
                PostInit: function () {
                    $('#submit').click(function () {
                        uploader.start();
                    });
                },

                FilesAdded: function (up, files) {
                    $('#now-avatar').slideUp('fast');
                    $('#crop-avatar').slideDown('fast');
                    this.splice(0, up.files.length - 1);
                    plupload.each(up.files, function (file) {
                        reader.readAsDataURL(file.getNative());
                    });
                },

                BeforeUpload: function (up, file) {
                    up.settings.multipart_params.crop_x1 = JCrop_x1;
                    up.settings.multipart_params.crop_y1 = JCrop_y1;
                    up.settings.multipart_params.crop_x2 = JCrop_x2;
                    up.settings.multipart_params.crop_y2 = JCrop_y2;
                    up.settings.multipart_params.crop_w = JCrop_w;
                    up.settings.multipart_params.crop_h = JCrop_h;
                    up.settings.multipart_params.file_ori_name = file.name;
                },

                UploadProgress: function (up, file) {
                    $('#upload-progress-bar').css('width', file.percent + '%');
                },

                Error: function (up, err) {
                    noty({type: 'error', text: 'err.code' + ' - ' + err.message});
                },

                FileUploaded: function (up, file, info) {
                    try {
                        var rsp = $.parseJSON(info.response);
                        noty({type: rsp.type, text: rsp.message, callback: {
                            afterClose: function () {
                                switch (rsp.type) {
                                    case 'success':
                                        location.reload();
                                        break;
                                    default:
                                        break;
                                }
                            }
                        }});
                    } catch (ex) {
                        noty({type: 'error', text: '发生内部错误，请联系管理员'});
                        throw ex;
                    }
                }
            }
        });

        $('#user-info-form').validate({
            submitHandler: function (form) {
                $.ajax({
                    url: '<?php echo base_url('api/setUserInfo');?>',
                    type: 'post',
                    data: $(form).serialize(),
                    success: function (jsonrsp) {
                        try {
                            var rsp = $.parseJSON(jsonrsp);
                            noty({type: rsp.type, text: rsp.message, callback: {
                                afterClose: function () {
                                    switch (rsp.type) {
                                        case 'success':
                                            //location.reload();
                                            break;
                                        default:
                                            break;
                                    }
                                }
                            }});
                        } catch (ex) {
                            noty({type: 'error', text: '发生内部错误，请联系管理员'});
                            throw ex;
                        }
                    }
                });
            }
        });

        //修改密码
        $('#change-password-form').validate({
            submitHandler:function(form){
                $.ajax({
                    url:'<?php echo base_url('api/changeUserPassword') ?>',
                    type:'post',
                    data:$(form).serialize(),
                    success:function(result){
                        try{
                            var res= $.parseJSON(result);
                            noty({type:res.type,text:res.message,callback:{
                                afterClose:function(){
                                    switch (res.type){
                                        case 'success':
                                            $.get(base_url('api/logout'), function () {
                                                location.reload();
                                            });
                                            break;
                                        default :
                                            break;
                                    }
                                }
                            }})

                        }catch (ex) {
                            noty({type: 'error', text: result.message});
                            throw ex;
                        }
                    }
                });
            }
        });

        uploader.init();

        //从URL改变TAB
        var url = document.location.toString();
        if (url.match('#')) {
            $('#userinfo-tab-menu a[href=#'+url.split('#')[1]+']').tab('show') ;
        }
        $('#userinfo-tab-menu a').on('click', function (e) {
            window.location.hash = e.target.hash;
        });
        //END 从URL改变TAB

        $('.js-user-contact').hide();
        switch ($('#user_contact_type').val()){
            case '<?php echo _ContactType_LongPhone?>':
                $('#user_phone').show();
                break;
            case '<?php echo _ContactType_ShortPhone?>':
                $('#user_phone_short').show();
                break;
            case '<?php echo _ContactType_Qq?>':
                $('#user_qq').show();
                break;
        }

        $('#user_contact_type').change(function(){
                $('.js-user-contact').hide();
                switch ($(this).val()){
                    case '<?php echo _ContactType_LongPhone?>':
                        $('#user_phone').show();
                        break;
                    case '<?php echo _ContactType_ShortPhone?>':
                        $('#user_phone_short').show();
                        break;
                    case '<?php echo _ContactType_Qq?>':
                        $('#user_qq').show();
                        break;
                }
            }
        );
    });
</script>
<!--选择城市-->
<script type="text/javascript" src="<?php echo base_url('public/cityselect/jquery.cityselect.js'); ?>"></script>
<script type="text/javascript">
$(function(){
	$("#location").citySelect({
    	prov:"<?php echo $thatUserInfo->getProv()?>",
    	city:"<?php echo $thatUserInfo->getCity()?>",
		dist:"<?php echo $thatUserInfo->getDist()?>",
		nodata:"none"
	}); 
});
</script>
<!--选择生日-->
<script src="<?php echo base_url('public/Date/manhuaDate.1.0.js'); ?>" type="text/javascript"></script>
<script type="text/javascript">
$(function (){
	$("#Ubirthday").manhuaDate({					       
	});
	$("*").not(".getyear *").on('click',function(){
		$(".calender").css("display","none");
	})
    $(".getyear *").on('click',function(event){
            event.stopPropagation();
    });
});

</script>
